package cn.itsource.utils;

/**
 * @program fccar_240420
 * @Description
 * @Date 2024/09/04 14:53
 * @Version 1.0
 */
public class IdUtil {
    public static final int WORKER_ID = 1;
    public static final int DATACENTER_ID = 1;

    /**
     * 得到一个雪花算法的id
     * @return
     */
    public static long getId(){
        return cn.hutool.core.util.IdUtil.createSnowflake(WORKER_ID,DATACENTER_ID).nextId();
    }

}
